package com.ckf.serene.service;

import com.ckf.serene.domain.VipOrderParam;
import com.ckf.serene.domain.WXPayParam;
import com.ckf.serene.domain.WeChatTransferParam;
import com.ckf.serene.domain.WxRefundParam;

import javax.servlet.http.HttpServletRequest;
import java.util.Map;

/**
 * 微信服务类
 *
 * @author serence
 * @date 2021/11/6 23:38
 */
public interface WeChatPayService {

    /**
     * 小程序支付V3
     *
     * @param payParam 支付参数类
     * @return
     */
    public Map<String, String> appletsV3(WXPayParam payParam);

    /**
     * 微信支付成功回调通知
     *
     * @param request 回调信息
     * @return
     */
    public String weChatPaySuccess(HttpServletRequest request);

    /**
     * 微信退款
     *
     * @param wxRefundParam 微信退款参数类
     * @return
     */
    public Map<String, String> weChatRefund(WxRefundParam wxRefundParam);

    /**
     * 微信退款成功回调通知
     *
     * @param request 回调信息
     * @return
     */
    public String weChatRefundCallback(HttpServletRequest request);

    /**
     * 获取微信退款详情
     *
     * @param wxRefundParam 微信退款参数类
     * @return
     */
    public Map<String, String> weChatQueryRefund(WxRefundParam wxRefundParam);

    /**
     * 企业转账到零钱  微信 方式二
     *
     * @param chatTransferParam 微信转账参数类
     * @return
     */
    public Map<String, String> weChatPaymentToChange(WeChatTransferParam chatTransferParam) ;

    /**
     * 查询企业付款到零钱
     *
     * @param chatTransferParam 微信转账参数类
     * @return
     */
    public String queryBusinessPaymentToChange(WeChatTransferParam chatTransferParam);

    /**
     * 获取RSA加密公钥
     *
     * @return
     */
    public Map<String, String> getPublicKey();

    /**
     * 获取平台证书
     *
     * @return
     */
    public Map<String, Object> getPlatformCertificate();

    /**
     * 企业付款到银行 方式二
     *
     * @param chatTransferParam 微信转账参数类
     * @return
     */
    public Map<String, String> corporatePaymentToBankCard(WeChatTransferParam chatTransferParam);

    /**
     * 查询企业付款到银行卡
     *
     * @param chatTransferParam 微信转账参数类
     * @return
     */
    public String queryCorporatePaymentToBankCard(WeChatTransferParam chatTransferParam);

    /**
     * 微信订单查询
     *
     * @param wxRefundParam 微信退款参数类
     * @return
     */
    public Map<String, String> weChatOrderQuery(WxRefundParam wxRefundParam);

    /**
     * 微信app支付
     *
     * @param payParam 微信支付参数类
     * @return
     */
    public Map<String, String> weChatAppPayment(WXPayParam payParam);

    /**
     * 微信app支付 V3版本
     *
     * @param param 微信支付传参类
     * @return
     */
    public Map<String, String> weChatAppPayV3(VipOrderParam param);

}
